package com.cqyanyu.yanyu.view.recyclerView;

import android.content.Context;
import android.support.v7.widget.RecyclerView;
import android.view.View;

/**
 * Created by cheng on 2016/7/16.
 */
public class YViewHolder<T> extends RecyclerView.ViewHolder implements View.OnClickListener {
    protected Context mContext;
    protected int position;

    public YViewHolder(View parent) {
        super(parent);
        mContext = parent.getContext();
        itemView.setOnClickListener(this);
    }

    /**
     * Adapter onBindViewHolder方法时调用
     * @param itemData
     */
    public void onBindViewHolder(T itemData) {
    }

    public void setPosition(int position) {
        this.position = position;
    }

    @Override
    public void onClick(View v) {

    }
}
